import request from '@/utils/request'

// 查询住房补贴管理列表
export function listHousingsubsidy(query) {
  return request({
    url: '/czj/housingsubsidy/list',
    method: 'get',
    params: query
  })
}

// 查询住房补贴管理详细
export function getHousingsubsidy(subsidyid) {
  return request({
    url: '/czj/housingsubsidy/' + subsidyid,
    method: 'get'
  })
}

// 新增住房补贴管理
export function addHousingsubsidy(data) {
  return request({
    url: '/czj/housingsubsidy',
    method: 'post',
    data: data
  })
}

// 修改住房补贴管理
export function updateHousingsubsidy(data) {
  return request({
    url: '/czj/housingsubsidy',
    method: 'put',
    data: data
  })
}

// 删除住房补贴管理
export function delHousingsubsidy(subsidyid) {
  return request({
    url: '/czj/housingsubsidy/' + subsidyid,
    method: 'delete'
  })
}
export function submitHousingsubsidy(subsidyid) {
  return request({
    url: '/czj/housingsubsidy/submitSubsidy',
    method: 'post',
    data: subsidyid
  })
}

//提交审批
export function approveStudent(data) {
  return request({
    url: '/czj/housingsubsidy/editnoapprove',
    method: 'post',
    data: data
  })
}

// 查询未审批的学生信息列表
export function listStudentNo(query) {
  return request({
    url: '/czj/housingsubsidy/listNo',
    method: 'get',
    params: query
  })
}

// 查询学生信息详细和批注
export function getStudentComment(studentId) {
  return request({
    url: '/czj/housingsubsidy/getStudentComment/' + studentId,
    method: 'get'
  })
}

export function listStudentFinished(query) {
  return request({
    url: '/czj/housingsubsidy/listFinished',
    method: 'post',
    data: query
  })
}
